package com.qy139.auth.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.qy139.entity.CardInfo;
import com.qy139.entity.TabUser;
import org.apache.ibatis.annotations.Param;

import java.util.Date;
import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author yuhaochen
 * @since 2021-12-01
 */
public interface TabUserMapper extends BaseMapper<TabUser> {
    //查询登录用户所拥有的角色
    List<String> findRolesById(Integer id);

    IPage<TabUser> selectAllUser(Page<TabUser> page, String name);

    //更改用户在/离职状态
    int updateStatus (TabUser user);
    //操作用户离职时获取其入职时间
    Date getHireDate(Integer id);
}
